From: Matthias Clasen Date: Thu, 2 Aug 2012 23:58:01 +0000 (+0200) Subject: Sync man page configury with GLib X-Git-Tag: archive/raspbian/3.24.39-1+rpi1~1^2~65^2~39^2~16721 X-Git-Url: https://dgit.raspbian.org/%22http://www.example.com/cgi/%22/%22http:/www.example.com/cgi/%22?a=commitdiff_plain;h=c5490474747c662fc0709fda79c596eebeefed2e;p=gtk%2B3.0.git Sync man page configury with GLib --- diff --git a/configure.ac b/configure.ac index 514fc04578..cd5f442eb9 100644 --- a/configure.ac +++ b/configure.ac @@ -1603,33 +1603,53 @@ AM_CONDITIONAL(HAVE_COLORD, test "x$have_colord" = "xyes") GTK_DOC_CHECK([1.11],[--flavour no-tmpl]) -AC_CHECK_PROG(DB2HTML, db2html, true, false) -AM_CONDITIONAL(HAVE_DOCBOOK, $DB2HTML) - AC_ARG_ENABLE(man, [AS_HELP_STRING([--enable-man], - [regenerate man pages from Docbook [default=no]])], - [enable_man=yes], - [enable_man=no]) - -if test "${enable_man}" != no; then - dnl - dnl Check for xsltproc - dnl + [generate man pages [default=auto]])],, + enable_man=maybe) + +if test "$enable_man" != no; then AC_PATH_PROG([XSLTPROC], [xsltproc]) if test -z "$XSLTPROC"; then + if test "$enable_man" = yes ; then + AC_MSG_ERROR([xsltproc is required for --enable-man]) + fi enable_man=no fi +fi - dnl check for DocBook DTD and stylesheets in the local catalog. +if test "$enable_man" != no; then + dnl check for DocBook DTD in the local catalog JH_CHECK_XML_CATALOG([-//OASIS//DTD DocBook XML V4.1.2//EN], - [DocBook XML DTD V4.1.2],,enable_man=no) + [DocBook XML DTD V4.1.2], [have_docbook_dtd=yes], [have_docbook_dtd=no]) + if test "$have_docbook_dtd" != yes; then + if test "$enable_man" = yes ; then + AC_MSG_ERROR([DocBook DTD is required for --enable-man]) + fi + enable_man=no + fi +fi + +if test "$enable_man" != no; then + dnl check for DocBook XSL stylesheets in the local catalog JH_CHECK_XML_CATALOG([http://docbook.sourceforge.net/release/xsl/current/manpages/docbook.xsl], - [DocBook XSL Stylesheets],,enable_man=no) + [DocBook XSL Stylesheets], [have_docbook_style=yes],[have_docbook_style=no]) + if test "$have_docbook_dtd" != yes; then + if test "$enable_man" = yes ; then + AC_MSG_ERROR([DocBook XSL Stylesheets are required for --enable-man]) + fi + enable_man=no + fi fi -AM_CONDITIONAL(ENABLE_MAN, test x$enable_man != xno) +AM_CONDITIONAL(ENABLE_MAN, test "$enable_man" != no) +AC_MSG_CHECKING([whether to generate man pages]) +if test "$enable_man" != no; then + AC_MSG_RESULT([yes]) +else + AC_MSG_RESULT([no]) +fi ################################################## # Output commands